<template>
  <common-card title="累计订单量" value="2,157,430">
    <template>
      <!-- main.js 注册的组件 options 相当于echart的options -->
      <!-- <vue-chart :options="getOptions()" /> -->
    </template>
    <template #footer>
      <span>昨日订单量 </span>
      <span class="emphasis">2,000,000</span>
    </template>
  </common-card>
</template>
<script>
import cardMixin from '../../mixins/cardMixin'
export default {
  name: 'TotalOrders',
  mixins: [cardMixin],
  methods: {
    getOptions() {
      return {
        xAxis: {
          type: 'category',
          show: false,
          boundaryGap: false // 取消X轴边距
        },
        yAxis: {
          show: false
        },
        grid: {
          top: 0,
          bottom: 0,
          left: 0,
          right: 0
        },
        series: [
          {
            type: 'line',
            data: [
              620, 432, 220, 534, 790, 430, 220, 320, 532, 320, 834, 690, 530,
              220, 620
            ],
            areaStyle: {
              color: 'purple'
            },
            lineStyle: {
              width: 0 // 线宽
            },
            itemStyle: {
              opacity: 0 // 折线点透明度
            },
            smooth: true // 平滑展示曲线
          }
        ]
      }
    }
  }
}
</script>
